package com.gxa.eshop.core.pojo;

import io.swagger.annotations.Api;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.data.mongodb.core.mapping.Field;

import javax.persistence.*;
import java.io.Serializable;
import java.util.Date;

@Data
@AllArgsConstructor
@NoArgsConstructor
@Table(name = "tb_goods")
@ApiModel("商品的实体类型")
public class Goods implements Serializable {
    @Id
    @GeneratedValue(strategy = GenerationType.IDENTITY)
    @Column(name = "goods_id")
    @ApiModelProperty(name="id",value = "商品编号id")
    private Long id;
    @Column(name ="goods_title")
    @ApiModelProperty(name="title",value = "商品名称")
    private String title;
    @Column(name ="goods_price")
    @ApiModelProperty(name="price",value = "商品价格")
    private Double price;
    @Column(name ="status")
    @ApiModelProperty(name="status",value = "商品的状态")
    private Integer status;
    @Column(name ="goods_created")
    @ApiModelProperty(name="created",value = "商品创建时间")
    private Date created;
}
